package com.shengde.jinwawaforleader.model.myJob.teachResource;

import android.app.Activity;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.webkit.WebSettings;
import android.webkit.WebView;
import android.widget.TextView;

import com.shengde.jinwawaforleader.R;


public class MingshiShipinDetailActivity extends Activity {

	private WebView show_wv;
	private TextView tv_title;

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		// TODO Auto-generated method stub
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_mingshi_shipin_detail);
		tv_title = (TextView)findViewById(R.id.tv_title);
		tv_title.setText(getString(R.string.shifankeshipin));
		String url = getIntent().getStringExtra("url");
		show_wv = (WebView) findViewById(R.id.show_wv);
		//		show_wv.loadUrl("http://www.baidu.com");
		//
		//		show_wv.setWebViewClient(new WebViewClient() {
		//			@Override
		//			public boolean shouldOverrideUrlLoading(WebView view, String url) {
		//				view.loadUrl(url);
		//				return true;
		//			}
		//		});
		WebSettings settings = show_wv.getSettings();
		settings.setJavaScriptEnabled(true);
		settings.setSupportZoom(true);
		settings.setBuiltInZoomControls(true);
		show_wv.loadUrl(url);
		findViewById(R.id.tv_back).setOnClickListener(new OnClickListener() {

			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
				finish();
			}
		});

	}

	@Override
	protected void onDestroy() {
		show_wv.destroy();
		super.onDestroy();
	}
}